package cn.tedu.spring.di;

import lombok.ToString;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.stereotype.Service;

/**
 * Created by IntelliJ IDEA.
 *
 * @author zq
 * @version 1.0
 * @create 2024-08-02 14:27
 * @since jdk1.8
 */
@Service
@ToString
public class UserService {
//    @Value("userService")
    private String serviceName;
    //@Autowired 注解 自动装配注解,注入对象是对象类型或接口类型
     @Autowired
    private UserDao userDao;
    @Autowired

    public void setUserDao(UserDao userDao) {
        this.userDao = userDao;
    }
}
